from aiogram_dialog import Dialog, Window
from aiogram_dialog.widgets.kbd import Cancel, Start

from src.bot.dialogs.getters.users import user_is_admin_getter
from src.bot.dialogs.widgets import LocaleText
from src.bot.states.admin import AdminSG, MailingSG

features_window = Window(
    LocaleText("select-option-msg"),
    Start(
        LocaleText("send-mailing-btn"),
        id="mailing",
        state=MailingSG.mailing_text,
    ),
    Cancel(
        LocaleText("back-btn"),
    ),
    state=AdminSG.admin,
    getter=user_is_admin_getter,
)

admin_features_dialog = Dialog(features_window)
